package com.workcell.workdata.im.component.event;

import com.workcell.workdata.im.constant.ChangeType;
import com.workcell.workdata.im.entity.Comment;
import com.workcell.workdata.im.entity.Message;
import org.springframework.context.ApplicationEvent;

import java.util.List;

public class CommentEvent extends ApplicationEvent {
    private final ChangeType type;
    private Message message;
    private List<Long> uidList;
    public CommentEvent(Comment comment, ChangeType type) {
        super(comment);
        this.type = type;
    }

    @Override
    public Comment getSource() {
        return (Comment) source;
    }

    public ChangeType getType() {
        return type;
    }

    public Message getMessage() {
        return message;
    }

    public void setMessage(Message message) {
        this.message = message;
    }

    public List<Long> getUidList() {
        return uidList;
    }

    public void setUidList(List<Long> uidList) {
        this.uidList = uidList;
    }
}
